//深拷贝       
export const deepCopy = (source) => {
    let target;
    if (typeof source === 'object') {
        target = Array.isArray(source) ? [] : {}
        for (let key in source) {
            if (source.hasOwnProperty(key)) {
                if (typeof source[key] !== 'object') {
                    target[key] = source[key]
                } else {
                    target[key] = deepCopy(source[key])
                }
            }
        }
    } else {
        target = source
    }
    return target
}